package com.uenpay.oem.util.input;

import android.content.Context;
import android.view.inputmethod.InputMethodManager;

/**
 * Created by DELL on 2017/6/28.
 */

public class InputUtils {
    /**
     * 切换键盘显示与隐藏
     * @param mcontext
     */
    public static void switchBoard(Context mcontext) {
        InputMethodManager imm = (InputMethodManager) mcontext
                .getSystemService(Context.INPUT_METHOD_SERVICE);
        if (imm.isActive())
            imm.toggleSoftInput(InputMethodManager.SHOW_IMPLICIT,
                    InputMethodManager.HIDE_NOT_ALWAYS);
    }
}
